package com.example.angulardemo.dao.impl;

import com.example.angulardemo.dao.UserDao;
import com.example.angulardemo.model.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @Description:
 * @Author:
 */
@Service
public class UserDaoImpl implements UserDao {

    @Autowired
    RoleDaoImpl roleDaoImpl;

    @Override
    public User findUserByName(String name) {
        User user = new User();
        user.setId(1);
        user.setName("admin");
        user.setPassword("123456");
        user.setState(1);
     //   user.setRoles(roleDaoImpl.findUserRoles(user.getId()));
        return user;
    }
}
